package com.itita.ww2.model.item.ds;

import com.itita.ww2.model.item.AbstractItem;
import com.smartfoxserver.v2.entities.data.ISFSObject;

/**
 * 物品值
 * @author NorthLan
 *
 */
public class ItemValue {
	private AbstractItem item;
	private int count;

	public ItemValue(AbstractItem item, int count) {
		this.item = item;
		this.count = count;
	}

	public AbstractItem getItem() {
		return item;
	}

	public void setItem(AbstractItem item) {
		this.item = item;
	}

	public int getCount() {
		return count;
	}

	public void setCount(int count) {
		this.count = count;
	}
	
	public ISFSObject toSFSObject(){
		ISFSObject ref = item.toSFSObject();
		ref.putInt("count", count);
		return ref;
	}
}
